'use strict';
module.exports = (app) => {
  const { STRING, INTEGER, TEXT } = app.Sequelize;
  const Recruit = app.model.define('w_recruit', {
    id: {
      type: INTEGER,
      primaryKey: true,
      autoIncrement: true,
    },
    name: {
      comment: '岗位名称',
      type: TEXT('long'),
      allowNull: false,
    },
    requirement: {
      comment: '岗位要求',
      type: TEXT('long'),
      allowNull: false,
    },
    desc: {
      comment: '岗位描述',
      type: TEXT('long'),
      allowNull: false,
    },
    salary: {
      comment: '薪资待遇',
      type: STRING,
      allowNull: false,
    },
    phone: {
      comment: '联系方式',
      type: STRING,
      allowNull: false,
    },
    address: {
      comment: '公司地址',
      type: TEXT('long'),
      allowNull: false,
    },
    projectId: {
      comment: '项目id',
      type: INTEGER,
      allowNull: false,
    },
  });
  return Recruit;
};
